Structure

Files

category - (products category items)
css - (page stylesheets)
less - (stylesheets with CSS pre-processor)
fonts - (the Font Awesome iconic font)
img - (all images)
js - (page Scripts)
components - (page JavaScript Components)
lib - (page plugins)
main.js - (JavaScript file and module loader)
index.html - (main page document)
sendmail.php - (mail sender php script)

HTML

The template is based on the Foundation Framework

The Foundation grid system consist of 12 columns. Width of each column is specified by the small-#, medium-#, and large-# classes.



If you need more information about the Foundation grid system, please visit the official foundation documentation.

CSS / Less

For style part of the template we are using Scalable and Modular Architecture for CSS/LESS and it has 2 core goals.

Increase the semantic value of html section and content
Decrease the expectation of a specific html structure

The purpose of SMACSS categorization is to reduse code repetition, to increse consistent experience, and to make the maintenance easier. Under SMACSS there are 5 general categories of css/less rules:

color - (stylesheets for the each theme color)
lib - (page scripts stylesheet)
modules - (stylesheets for the each theme block)
_about.less - (about us section)
_team.less - (team section)
_preloader.less - (page preloader)
...
_base.less - (global styles and resets for this theme)
_theme.less - (theme variables and general components styles)
_layout.less - (classes and styles that define the theme layout)
_module.less - (stylesheet for the each theme component)
style.less - (all the less files)
welcome.less - (welcome page styles)

JavaScript

Is very important how you structure your JavaScript because:

If done right, it makes code easier to understand for others and yourself when re-visting your own code.
Having a decided-upon structure helps keeping future code clean and encourages your declared best practices.
It makes your code testable.

For JavaScript design pattern we are using "Module Pattern", which helps keep the units of code both cleanly separated and well organized.

Each module object is a separate file and is loaded on the page with the help of RequireJS, JavaScript file and module loader.

Here is how a module looks like.




For more about JavaScript module pattern read the How Do You Structure JavaScript? The Module Pattern Edition article.

Customization & Styles

Minify javascript

First, make sure you have installed nodeJS.

For windows platform just run minify.bat from the js folder.

For other platforms run in terminal from the js folder following command:

node tools/r.js -o tools/build.js

Theme color

To change the theme color, change the data color of the body tag.



These are our theme colors.

red
green
pink
orange
yellow

Currency

To change the theme currency, write it inside the data-currency attribute on body tag.



Font Family

To change the embedded font, find in the page head link tags.



To change the font, first go to Google Fonts, choose a font and replace the code above with the generated code.

Next find the _theme.less file in the css/less directory.

At the begining of the document find font variables and change it's content with your new font name

Nav item

Search in your html file this code block. Copy and paste a list item to add a new nav.



Anchor href attribute must match an id of a block, where page will scroll to on click.

Product item

To add a new product item, find its category html document in categories directory and copy a list item in products-list block.



Category item

To add a new category item, find category-list block and copy a list item.



Next, create a new html file and name it the same as data-category content(it is required for category html to have the name exactly the same as data-category content)

In your new category html file paste following markup and start adding product items



Main slider

To add a new slider item, search for the text-slider block and copy/paste a slider item.



Text slider

To add a new slider item, search for the slider-container block and copy/paste an item.



Carousel

To add a new carousel item in ingredients block, copy/paste a slide item and set the paths to your images



Testimonial slider

To add a new testimonial, search for the testimonials-images-list block and copy/paste a slide item.



Video

Add your video in three required extensions(.mp4, .ogg, .webm) in the video directory plus, an image to be shown on devices that does not support html5 video and set path to them in your html.



Icons

To change an icon chose a new one from Font Awesome icons change icon class(fa-university).



If you need more information, please visit this site: Font Awesome official page.

Source & Credits

Fonts Source

Typography Fonts - Google Fonts

Scripts Source

JavaScript library - jQuery
Front-end framework - Foundation
Front-end MVC framework - Backbone.js
Slider - OWL Carousel
Lightbox - Fancybox
File and module loader - RequireJS
Accelerated JavaScript animation - Velocity.js
On scroll reveal animations - Velocity.js, jquery.inview

General Info

Responsive

Fully Responsive

Browser Support

Chrome, Firefox, Opera, Safari, IE9+